package com.xie.gulimall.ware.feign;

import com.xie.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author xiefeixiang
 */
@FeignClient("gulimall-product")
public interface ProductFeignService {
    /**
     * 1.可以所有请求过网关 @FeignClient("gulimall-gateway") 、api/product/spuinfo/info/{id}
     * 2.直接对相应服务发请求 @FeignClient("gulimall-product")  /product/spuinfo/info/{id}"
     * @param id
     * @return
     */
    @RequestMapping("/product/spuinfo/info/{id}")
    public R info(@PathVariable("id") Long id);


}
